#include <iostream>
#include <string>
#include <vector>
#include <sstream>
#include "Movie.h"
#include "MovieRegister.h"
using namespace std;


int main3_1_2()
{
	Movie m1;
	Movie m2 = { "Barbie", "alex r", 130, true, false };

	m1.ReadMovie();
	m1.WriteMovie();

	m2.WriteMovie();

	return 1;
}

int main3_3()
{
	Movie m1 = { "Warriors", "alex r", 130, true, true };
	Movie m2;

	cout << m1;
	cin >> m2;
	cout << m2;

	return 1;
}

int main3_4()
{
	MovieRegister v1;
	Movie m1( "Warriors", "Alex R", 140, true, false);
	Movie m2( "Barbie", "barbie s", 100, false, true);

	v1.Add(m1);
	v1.Add(m2);
	v1.Delete(1);
	cout << v1.List();


	return 1;
}

int main3_5_6()
{
	MovieRegister w1;
	Movie m1{ "hej", "alex s", 105, 1, 1 };
	Movie m2{ "Warriors", "alez r", 130, 1, 0 };

	w1.WriteToFile(m1);
	w1.WriteToFile(m2);
	w1.ReadFromFile();

	return 1;
}

int main()
{
	//main3_1_2();
	//main3_3();
	//main3_4();
	main3_5_6();


	system("pause");

	return 0;
}